home *** CD-ROM | disk | FTP | other *** search
/ Chip: Internet / Chip Internet.iso / viewer / sox7dos / makefile.unx < prev    next >
Makefile  |  1993-02-11  |  3KB  |  123 lines

  1.  
  2. # Sound Tools Makefile
  3. #     builds libst.a and sox
  4.  
  5. FSRC= raw.c voc.c au.c sf.c aiff.c hcom.c 8svx.c sndrtool.c wav.c \
  6.     smp.c sbdsp.c auto.c
  7. ESRC= copy.c avg.c pred.c stat.c vibro.c echo.c rate.c band.c lowp.c reverse.c
  8. PSRC= sox.c
  9.  
  10. SOURCES   = $(PSRC) $(FSRC) $(ESRC) handlers.c libst.c misc.c getopt.c
  11.  
  12. HEADERS   = st.h libst.h sfheader.h patchlvl.h 
  13.  
  14. TESTS     = tests.sh monkey.au monkey.voc
  15.  
  16. MISC      = README INSTALL TODO sox.man sox.txt st.man Makefile.unx \
  17.         Makefile.bor sbprog.doc 
  18.  
  19. SKEL      = skel.c skeleff.c
  20.  
  21. VMS       = descrip.mms sound2au.com sound2sun.c sound2sun.opt \
  22.         sox.opt tests.com vms.lis
  23.  
  24. AMIGA      = Makefile.ami amiga.c amiga.h
  25.  
  26. FILES     = $(MISC) $(HEADERS) $(SOURCES) $(VMS) $(AMIGA) $(SKEL) $(TESTS)
  27.  
  28. FOBJ= raw.o voc.o au.o sf.o aiff.o hcom.o 8svx.o sndrtool.o wav.o \
  29.     smp.o sbdsp.o auto.o
  30. EOBJ= copy.o avg.o pred.o stat.o vibro.o echo.o rate.o band.o lowp.o reverse.o
  31.  
  32. SOUNDLIB  = libst.a
  33. LIBOBJS   = $(FOBJ) $(EOBJ) handlers.o libst.o misc.o getopt.o
  34.  
  35. #
  36. # System dependency parameters
  37. #     not many, we don't mess with devices
  38. #
  39. # include -DSYSV for AT&T Unix System V
  40.  
  41. # define -DBLASTER to use the Sound Blaster device driver
  42. # on a 386 AT&T Unix with it installed
  43.  
  44. # define -DSBLAST to use Steve Haenichen's SBLAST
  45. # driver on any BSD-derived Unix for 386/486 PC's
  46. # BSDI's BSD386, Jolitz 386BSD, or Mt Xinu's Mach-386
  47.  
  48. # define -DDOS  to compile on PC
  49. # defines .snd to mean a DOS soundtool file (starts with SOUND)
  50.  
  51. # define -DNeXT on a NeXT workstation
  52. # defines .snd to mean a NeXT sound format file
  53. #      only knows a few real sound formats.
  54.  
  55. # define -DMAC on a MacIntosh
  56. # defines .snd to mean a Mac-style headerless unsigned byte
  57. #      sample, probably at 11050 hertz.  You'll have to set 
  58. #    the speed on the command line.
  59.  
  60.  
  61. # My AT&T System V/386 development parameters
  62.  
  63. O=-g        # optimization flags
  64.  
  65. CFLAGS    = $O -DSYSV -DBLASTER
  66. CC        = gcc -fpcc-struct-return
  67. CC      = cc
  68. AR        = ar r
  69. RANLIB    = ar ts
  70.  
  71. # AT&T System V
  72.  
  73. # CFLAGS    = $O -DSYSV 
  74. # Gcc is better, of course, if you have it
  75. # CC        = gcc -fpcc-struct-return    
  76. # CC        = cc
  77. # AR        = ar r
  78. # RANLIB    = ar ts
  79.  
  80. # BSD-ish, salt to taste
  81. # Sun, NeXT, Vax, Ultrix uses these
  82.  
  83. # CFLAGS    = $O 
  84. # CC        = cc
  85. # AR        = ar r
  86. # RANLIB    = ranlib
  87.  
  88. # BSD-386, Mach 386, 386BSD, use for SBLAST driver
  89.  
  90. # CFLAGS    = $O -I/usr/src/sys -DSBLAST
  91. # CC        = /usr/local/bin/gcc
  92. # AR        = ar r
  93. # RANLIB    = ranlib
  94.  
  95. all: sox
  96.  
  97. sox: sox.o $(SOUNDLIB)
  98.     $(CC) $(CFLAGS) -o sox sox.o $(SOUNDLIB) -lm
  99.  
  100. $(SOUNDLIB): $(LIBOBJS)
  101.     rm -f $(SOUNDLIB)
  102.     $(AR) $(SOUNDLIB) $(LIBOBJS)
  103.     $(RANLIB) $(SOUNDLIB)
  104.  
  105. sox.o:        sox.c st.h
  106.  
  107. $(LIBOBJS):    st.h
  108.  
  109. sox.txt: sox.man
  110.     rm -f sox.txt
  111.     nroff -man sox.man | col > sox.txt
  112.  
  113. clean:
  114.     rm -f *.o
  115.     rm -f *.raw
  116.     rm -f *.sf
  117.     rm -f core
  118.  
  119. # Shar: -F (prefix all lines with X), 
  120. #     -s addr (set return addr of poster)
  121. shar: $(FILES)
  122.     /usr2/tools/shar/shar -M -F -l 50 -o shar -n soundtools_v6 -s thinman@netcom.com $(FILES)
  123.